package com.ztc.ZtcWalletLog.web;

import com.ztc.ZtcWalletLog.service.ZtcWalletLogManager;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.HashMap;


@Controller
@RequestMapping("ztc/walletLog")
public class ZtcWalletLogAction {

    @Autowired
    private ZtcWalletLogManager ztcWalletLogManager;


    /**
     * 获取app用户收支明细.
     * @param account   用户账户
     * @param pageNumber  页码
     * @param pageSize  每页大小
     * @return
     */
    @ResponseBody
    @RequestMapping("getZtcWalletLog")
    public HashMap<String,Object> getZtcWalletLog(String account, @RequestParam(defaultValue ="1") Integer pageNumber, @RequestParam(defaultValue ="10") Integer pageSize,String startTime,String endTime) {
       return ztcWalletLogManager.getZtcWalletLogByAccount(account,pageNumber,pageSize,startTime,endTime);
    }
}